package com.zhxi.gulimall.product.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.zhxi.common.utils.PageUtils;
import com.zhxi.common.utils.R;
import com.zhxi.gulimall.product.entity.AttrEntity;
import com.zhxi.gulimall.product.vo.AttrGroupRelationVo;
import com.zhxi.gulimall.product.vo.AttrVo;

import java.util.List;
import java.util.Map;

/**
 * 商品属性
 *
 * @Author: zhxi
 * @Email: 664480310@qq.com
 * @Date: 2024-08-19 17:41:15
 * @Version: 1.0.0
 */
public interface AttrService extends IService<AttrEntity> {

    PageUtils queryPage(Map<String, Object> params);

    void saveDetail(AttrVo attr);

    R queryBasePage(Map<String, Object> params, Long catelogId,String attrType);

    R getAttrInfo(Long attrId);

    void updateAttr(AttrVo attr);

    List<AttrEntity> attrRelation(long attrgroupId);

    void deleteRelation(List<AttrGroupRelationVo> list);

    PageUtils getNoRelationAttr(Map<String, Object> params, long attrgroupId);

    List<AttrEntity> getRelationAttr(Long attrGroupId);
/**
 * @param attrIds
 * @return {@link List<Long> }
 * @description: 在指定集合里找出可检索属性
 * @author: zx
 * @date: 2024-10-15 15:38
 */
    List<Long> selectSearchAttrs(List<Long> attrIds);
}

